﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace L05
{
    class Program
    {
        static void Main(string[] args)
        {
            Console.WriteLine("分析弹砖块游戏的实现，对主要代码进行说明:\n");

            Console.WriteLine("private void From1_Load(object sender, EventArgs e)");
            Console.WriteLine("用来载入挡板并设置挡板的位置以及活动区域\n");

            Console.WriteLine("private void LoadPictures()");
            Console.WriteLine("载入图片资源\n");

            Console.WriteLine("protected override void OnPaint(PaintEventArgs e)");
            Console.WriteLine("利用双缓冲机制绘制游戏界面\n");

            Console.WriteLine("private void DrawGame(Graphics g)");
            Console.WriteLine("绘制游戏界面（背景、挡板、砖块、弹球及文本信息）\n");

            Console.WriteLine("private void From1_MouseMove(object sender, MouseEventArgs e)");
            Console.WriteLine("利用鼠标移动控制挡板\n");

            Console.WriteLine("private void RandomBlockMap()");
            Console.WriteLine("产生随机的砖块\n");

            Console.WriteLine("private void TimerRefreshScreen_Tick(object sender, EventArgs e)");
            Console.WriteLine("使用Timer计时器刷新屏幕显示\n");

            Console.WriteLine("private void TimerWait_Tick(object sender, EventArgs e)");
            Console.WriteLine("使用Timer工具控制关卡等待时间\n");

            Console.WriteLine("private void TimerAfterSound_Tick(object sender, EventArgs e)");
            Console.WriteLine("使用Timer工具控制音效的播放间隔\n");

            Console.WriteLine("private bool IsHit()");
            Console.WriteLine("设定弹球的运动方式\n");

            Console.WriteLine("private bool IsKill()");
            Console.WriteLine("定义弹球碰撞砖块的运动模式并使被碰撞的砖块消失\n");

            Console.WriteLine("private void Play(string waveName)");
            Console.WriteLine("使用并播放游戏音效\n");

            Console.WriteLine("private bool IsLost()");
            Console.WriteLine("判断挡板是否接住了弹球\n");

            Console.WriteLine("private bool IsVictory()");
            Console.WriteLine("判断当前关节是否完成\n");

            Console.WriteLine("private void IsGameOver()");
            Console.WriteLine("判断游戏是否结束\n");

            Console.ReadKey();
        }
    }
}
